package cn.wildfirechat.app.webhook.github.pojo;

import com.google.gson.Gson;

public class ForkEvent {
    public Forkee forkee;
    public Repository repository;
    public User sender;

    public static ForkEvent fromJson(String jsonStr) {
        return new Gson().fromJson(jsonStr, ForkEvent.class);
    }
    public static void main(String[] args) {
        String event1 = "{\"forkee\":{\"id\":242609213,\"node_id\":\"MDEwOlJlcG9zaXRvcnkyNDI2MDkyMTM=\",\"name\":\"server\",\"full_name\":\"yangwugui/server\",\"private\":false,\"owner\":{\"login\":\"yangwugui\",\"id\":9507380,\"node_id\":\"MDQ6VXNlcjk1MDczODA=\",\"avatar_url\":\"https://avatars3.githubusercontent.com/u/9507380?v=4\",\"gravatar_id\":\"\",\"url\":\"https://api.github.com/users/yangwugui\",\"html_url\":\"https://github.com/yangwugui\",\"followers_url\":\"https://api.github.com/users/yangwugui/followers\",\"following_url\":\"https://api.github.com/users/yangwugui/following{/other_user}\",\"gists_url\":\"https://api.github.com/users/yangwugui/gists{/gist_id}\",\"starred_url\":\"https://api.github.com/users/yangwugui/starred{/owner}{/repo}\",\"subscriptions_url\":\"https://api.github.com/users/yangwugui/subscriptions\",\"organizations_url\":\"https://api.github.com/users/yangwugui/orgs\",\"repos_url\":\"https://api.github.com/users/yangwugui/repos\",\"events_url\":\"https://api.github.com/users/yangwugui/events{/privacy}\",\"received_events_url\":\"https://api.github.com/users/yangwugui/received_events\",\"type\":\"User\",\"site_admin\":false},\"html_url\":\"https://github.com/yangwugui/server\",\"description\":\"即时通讯(IM)系统\",\"fork\":true,\"url\":\"https://api.github.com/repos/yangwugui/server\",\"forks_url\":\"https://api.github.com/repos/yangwugui/server/forks\",\"keys_url\":\"https://api.github.com/repos/yangwugui/server/keys{/key_id}\",\"collaborators_url\":\"https://api.github.com/repos/yangwugui/server/collaborators{/collaborator}\",\"teams_url\":\"https://api.github.com/repos/yangwugui/server/teams\",\"hooks_url\":\"https://api.github.com/repos/yangwugui/server/hooks\",\"issue_events_url\":\"https://api.github.com/repos/yangwugui/server/issues/events{/number}\",\"events_url\":\"https://api.github.com/repos/yangwugui/server/events\",\"assignees_url\":\"https://api.github.com/repos/yangwugui/server/assignees{/user}\",\"branches_url\":\"https://api.github.com/repos/yangwugui/server/branches{/branch}\",\"tags_url\":\"https://api.github.com/repos/yangwugui/server/tags\",\"blobs_url\":\"https://api.github.com/repos/yangwugui/server/git/blobs{/sha}\",\"git_tags_url\":\"https://api.github.com/repos/yangwugui/server/git/tags{/sha}\",\"git_refs_url\":\"https://api.github.com/repos/yangwugui/server/git/refs{/sha}\",\"trees_url\":\"https://api.github.com/repos/yangwugui/server/git/trees{/sha}\",\"statuses_url\":\"https://api.github.com/repos/yangwugui/server/statuses/{sha}\",\"languages_url\":\"https://api.github.com/repos/yangwugui/server/languages\",\"stargazers_url\":\"https://api.github.com/repos/yangwugui/server/stargazers\",\"contributors_url\":\"https://api.github.com/repos/yangwugui/server/contributors\",\"subscribers_url\":\"https://api.github.com/repos/yangwugui/server/subscribers\",\"subscription_url\":\"https://api.github.com/repos/yangwugui/server/subscription\",\"commits_url\":\"https://api.github.com/repos/yangwugui/server/commits{/sha}\",\"git_commits_url\":\"https://api.github.com/repos/yangwugui/server/git/commits{/sha}\",\"comments_url\":\"https://api.github.com/repos/yangwugui/server/comments{/number}\",\"issue_comment_url\":\"https://api.github.com/repos/yangwugui/server/issues/comments{/number}\",\"contents_url\":\"https://api.github.com/repos/yangwugui/server/contents/{+path}\",\"compare_url\":\"https://api.github.com/repos/yangwugui/server/compare/{base}...{head}\",\"merges_url\":\"https://api.github.com/repos/yangwugui/server/merges\",\"archive_url\":\"https://api.github.com/repos/yangwugui/server/{archive_format}{/ref}\",\"downloads_url\":\"https://api.github.com/repos/yangwugui/server/downloads\",\"issues_url\":\"https://api.github.com/repos/yangwugui/server/issues{/number}\",\"pulls_url\":\"https://api.github.com/repos/yangwugui/server/pulls{/number}\",\"milestones_url\":\"https://api.github.com/repos/yangwugui/server/milestones{/number}\",\"notifications_url\":\"https://api.github.com/repos/yangwugui/server/notifications{?since,all,participating}\",\"labels_url\":\"https://api.github.com/repos/yangwugui/server/labels{/name}\",\"releases_url\":\"https://api.github.com/repos/yangwugui/server/releases{/id}\",\"deployments_url\":\"https://api.github.com/repos/yangwugui/server/deployments\",\"created_at\":\"2020-02-23T23:40:41Z\",\"updated_at\":\"2020-02-23T03:38:30Z\",\"pushed_at\":\"2020-02-21T03:20:03Z\",\"git_url\":\"git://github.com/yangwugui/server.git\",\"ssh_url\":\"git@github.com:yangwugui/server.git\",\"clone_url\":\"https://github.com/yangwugui/server.git\",\"svn_url\":\"https://github.com/yangwugui/server\",\"homepage\":\"http://docs.wildfirechat.cn\",\"size\":8928,\"stargazers_count\":0,\"watchers_count\":0,\"language\":null,\"has_issues\":false,\"has_projects\":true,\"has_downloads\":true,\"has_wiki\":true,\"has_pages\":false,\"forks_count\":0,\"mirror_url\":null,\"archived\":false,\"disabled\":false,\"open_issues_count\":0,\"license\":{\"key\":\"other\",\"name\":\"Other\",\"spdx_id\":\"NOASSERTION\",\"url\":null,\"node_id\":\"MDc6TGljZW5zZTA=\"},\"forks\":0,\"open_issues\":0,\"watchers\":0,\"default_branch\":\"master\",\"public\":true},\"repository\":{\"id\":167204613,\"node_id\":\"MDEwOlJlcG9zaXRvcnkxNjcyMDQ2MTM=\",\"name\":\"server\",\"full_name\":\"wildfirechat/server\",\"private\":false,\"owner\":{\"login\":\"wildfirechat\",\"id\":33191460,\"node_id\":\"MDEyOk9yZ2FuaXphdGlvbjMzMTkxNDYw\",\"avatar_url\":\"https://avatars0.githubusercontent.com/u/33191460?v=4\",\"gravatar_id\":\"\",\"url\":\"https://api.github.com/users/wildfirechat\",\"html_url\":\"https://github.com/wildfirechat\",\"followers_url\":\"https://api.github.com/users/wildfirechat/followers\",\"following_url\":\"https://api.github.com/users/wildfirechat/following{/other_user}\",\"gists_url\":\"https://api.github.com/users/wildfirechat/gists{/gist_id}\",\"starred_url\":\"https://api.github.com/users/wildfirechat/starred{/owner}{/repo}\",\"subscriptions_url\":\"https://api.github.com/users/wildfirechat/subscriptions\",\"organizations_url\":\"https://api.github.com/users/wildfirechat/orgs\",\"repos_url\":\"https://api.github.com/users/wildfirechat/repos\",\"events_url\":\"https://api.github.com/users/wildfirechat/events{/privacy}\",\"received_events_url\":\"https://api.github.com/users/wildfirechat/received_events\",\"type\":\"Organization\",\"site_admin\":false},\"html_url\":\"https://github.com/wildfirechat/server\",\"description\":\"即时通讯(IM)系统\",\"fork\":false,\"url\":\"https://api.github.com/repos/wildfirechat/server\",\"forks_url\":\"https://api.github.com/repos/wildfirechat/server/forks\",\"keys_url\":\"https://api.github.com/repos/wildfirechat/server/keys{/key_id}\",\"collaborators_url\":\"https://api.github.com/repos/wildfirechat/server/collaborators{/collaborator}\",\"teams_url\":\"https://api.github.com/repos/wildfirechat/server/teams\",\"hooks_url\":\"https://api.github.com/repos/wildfirechat/server/hooks\",\"issue_events_url\":\"https://api.github.com/repos/wildfirechat/server/issues/events{/number}\",\"events_url\":\"https://api.github.com/repos/wildfirechat/server/events\",\"assignees_url\":\"https://api.github.com/repos/wildfirechat/server/assignees{/user}\",\"branches_url\":\"https://api.github.com/repos/wildfirechat/server/branches{/branch}\",\"tags_url\":\"https://api.github.com/repos/wildfirechat/server/tags\",\"blobs_url\":\"https://api.github.com/repos/wildfirechat/server/git/blobs{/sha}\",\"git_tags_url\":\"https://api.github.com/repos/wildfirechat/server/git/tags{/sha}\",\"git_refs_url\":\"https://api.github.com/repos/wildfirechat/server/git/refs{/sha}\",\"trees_url\":\"https://api.github.com/repos/wildfirechat/server/git/trees{/sha}\",\"statuses_url\":\"https://api.github.com/repos/wildfirechat/server/statuses/{sha}\",\"languages_url\":\"https://api.github.com/repos/wildfirechat/server/languages\",\"stargazers_url\":\"https://api.github.com/repos/wildfirechat/server/stargazers\",\"contributors_url\":\"https://api.github.com/repos/wildfirechat/server/contributors\",\"subscribers_url\":\"https://api.github.com/repos/wildfirechat/server/subscribers\",\"subscription_url\":\"https://api.github.com/repos/wildfirechat/server/subscription\",\"commits_url\":\"https://api.github.com/repos/wildfirechat/server/commits{/sha}\",\"git_commits_url\":\"https://api.github.com/repos/wildfirechat/server/git/commits{/sha}\",\"comments_url\":\"https://api.github.com/repos/wildfirechat/server/comments{/number}\",\"issue_comment_url\":\"https://api.github.com/repos/wildfirechat/server/issues/comments{/number}\",\"contents_url\":\"https://api.github.com/repos/wildfirechat/server/contents/{+path}\",\"compare_url\":\"https://api.github.com/repos/wildfirechat/server/compare/{base}...{head}\",\"merges_url\":\"https://api.github.com/repos/wildfirechat/server/merges\",\"archive_url\":\"https://api.github.com/repos/wildfirechat/server/{archive_format}{/ref}\",\"downloads_url\":\"https://api.github.com/repos/wildfirechat/server/downloads\",\"issues_url\":\"https://api.github.com/repos/wildfirechat/server/issues{/number}\",\"pulls_url\":\"https://api.github.com/repos/wildfirechat/server/pulls{/number}\",\"milestones_url\":\"https://api.github.com/repos/wildfirechat/server/milestones{/number}\",\"notifications_url\":\"https://api.github.com/repos/wildfirechat/server/notifications{?since,all,participating}\",\"labels_url\":\"https://api.github.com/repos/wildfirechat/server/labels{/name}\",\"releases_url\":\"https://api.github.com/repos/wildfirechat/server/releases{/id}\",\"deployments_url\":\"https://api.github.com/repos/wildfirechat/server/deployments\",\"created_at\":\"2019-01-23T15:21:28Z\",\"updated_at\":\"2020-02-23T03:38:30Z\",\"pushed_at\":\"2020-02-21T03:20:03Z\",\"git_url\":\"git://github.com/wildfirechat/server.git\",\"ssh_url\":\"git@github.com:wildfirechat/server.git\",\"clone_url\":\"https://github.com/wildfirechat/server.git\",\"svn_url\":\"https://github.com/wildfirechat/server\",\"homepage\":\"http://docs.wildfirechat.cn\",\"size\":8928,\"stargazers_count\":4694,\"watchers_count\":4694,\"language\":\"Java\",\"has_issues\":true,\"has_projects\":true,\"has_downloads\":true,\"has_wiki\":true,\"has_pages\":false,\"forks_count\":1040,\"mirror_url\":null,\"archived\":false,\"disabled\":false,\"open_issues_count\":14,\"license\":{\"key\":\"other\",\"name\":\"Other\",\"spdx_id\":\"NOASSERTION\",\"url\":null,\"node_id\":\"MDc6TGljZW5zZTA=\"},\"forks\":1040,\"open_issues\":14,\"watchers\":4694,\"default_branch\":\"wildfirechat\"},\"organization\":{\"login\":\"wildfirechat\",\"id\":33191460,\"node_id\":\"MDEyOk9yZ2FuaXphdGlvbjMzMTkxNDYw\",\"url\":\"https://api.github.com/orgs/wildfirechat\",\"repos_url\":\"https://api.github.com/orgs/wildfirechat/repos\",\"events_url\":\"https://api.github.com/orgs/wildfirechat/events\",\"hooks_url\":\"https://api.github.com/orgs/wildfirechat/hooks\",\"issues_url\":\"https://api.github.com/orgs/wildfirechat/issues\",\"members_url\":\"https://api.github.com/orgs/wildfirechat/members{/member}\",\"public_members_url\":\"https://api.github.com/orgs/wildfirechat/public_members{/member}\",\"avatar_url\":\"https://avatars0.githubusercontent.com/u/33191460?v=4\",\"description\":\"北京野火无限网络科技有限公司--专注于即时通讯技术，提供优质可控的即时通讯能力\"},\"sender\":{\"login\":\"yangwugui\",\"id\":9507380,\"node_id\":\"MDQ6VXNlcjk1MDczODA=\",\"avatar_url\":\"https://avatars3.githubusercontent.com/u/9507380?v=4\",\"gravatar_id\":\"\",\"url\":\"https://api.github.com/users/yangwugui\",\"html_url\":\"https://github.com/yangwugui\",\"followers_url\":\"https://api.github.com/users/yangwugui/followers\",\"following_url\":\"https://api.github.com/users/yangwugui/following{/other_user}\",\"gists_url\":\"https://api.github.com/users/yangwugui/gists{/gist_id}\",\"starred_url\":\"https://api.github.com/users/yangwugui/starred{/owner}{/repo}\",\"subscriptions_url\":\"https://api.github.com/users/yangwugui/subscriptions\",\"organizations_url\":\"https://api.github.com/users/yangwugui/orgs\",\"repos_url\":\"https://api.github.com/users/yangwugui/repos\",\"events_url\":\"https://api.github.com/users/yangwugui/events{/privacy}\",\"received_events_url\":\"https://api.github.com/users/yangwugui/received_events\",\"type\":\"User\",\"site_admin\":false}}";
        ForkEvent forkEvent = fromJson(event1);
        System.out.println(forkEvent.forkee.fork);
    }
}
